<?php

return [
    'User' => [
        'Auth' => [
            'LoginRequest' => [
                'phone' => ['required' => '请输入手机号码', 'regex' => '手机号码格式错误'],
                'login_pwd' => ['required' => '请输入密码', 'confirmed' => '两次密码不一致'],
                'login_pwd_confirmation' => ['required' => '请再次确定密码'],
                'code' => ['required' => '请输入验证码', 'digits' => '验证码格式错误（6位数字）'],
                'invitation_code' => ['size' => '邀请码格式错误']
            ],
            'CodeRequest' => [
                'phone' => ['required' => '请输入手机号码', 'regex' => '手机号码格式错误'],
            ],
            'retrieveRequest' => [
                'phone' => ['required' => '请输入手机号码', 'regex' => '手机号码格式错误'],
                'login_pwd' => ['required' => '请输入密码', 'confirmed' => '两次密码不一致'],
                'login_pwd_confirmation' => ['required' => '请再次确定密码'],
            ],
            'retrievePhoneRequest' => [
                'phone' => ['required' => '请输入手机号码', 'regex' => '手机号码格式错误'],
                'code' => ['required' => '请输入验证码', 'digits' => '验证码格式错误（6位数字）'],
            ]
        ],
        'Advertising' => [
            'IndexRequest' => [
                'type' => ['required' => '请输入广告类型', 'integer' => '广告类型格式错误'],
            ]
        ],
        'UserAddr' => [
            'CreateRequest' => [
                'name' => ['required' => '请输入收货人', 'string' => '收货人格式错误', 'between' => '收货人长度错误'],
                'phone' => ['required' => '请输入手机号码', 'regex' => '手机号格式错误'],
                'province' => ['required' => '请选择所在省', 'string' => '省份错误，请重新选择', 'between' => '省份错误，请重新选择'],
                'city' => ['required' => '请选择所在市', 'string' => '城市错误，请重新选择', 'between' => '省份错误，请重新选择'],
                'district' => ['required' => '请选择所在区/县', 'string' => '区/县错误，请重新选择', 'between' => '省份错误，请重新选择'],
                'area_ids' => ['required' => '所选地区无效，请重新选择', 'json' => '所选地区无效，请重新选择'],
                'address' => ['required' => '请输入详细地址', 'string' => '详细地址格式错误', 'between' => '详细地址格式错误'],
                'zip_code' => ['size' => '邮编格式错误'],
                'remark' => ['between' => '备注格式错误']
            ],
            'EditRequest' => [
                'id' => ['required' => '数据异常，请刷新重试', 'integer' => '数据异常，请刷新重试'],
                'name' => ['required' => '请输入收货人', 'string' => '收货人格式错误', 'between' => '收货人长度错误'],
                'phone' => ['required' => '请输入手机号码', 'regex' => '手机号格式错误'],
                'province' => ['required' => '请选择所在省', 'string' => '省份错误，请重新选择', 'between' => '省份错误，请重新选择'],
                'city' => ['required' => '请选择所在市', 'string' => '城市错误，请重新选择', 'between' => '省份错误，请重新选择'],
                'district' => ['required' => '请选择所在区/县', 'string' => '区/县错误，请重新选择', 'between' => '省份错误，请重新选择'],
                'area_ids' => ['required' => '所选地区无效，请重新选择', 'json' => '所选地区无效，请重新选择'],
                'address' => ['required' => '请输入详细地址', 'string' => '详细地址格式错误', 'between' => '详细地址格式错误'],
                'zip_code' => ['size' => '邮编格式错误'],
                'remark' => ['between' => '备注格式错误']
            ]
        ],
        'Coupon' => [
            'SearchRequest' => [
                'keywords' => ['required' => '请输入搜索关键词'],
                'max_price' => ['numeric' => '最高价只能是数字'],
                'min_price' => ['numeric' => '最低价只能是数字'],
                'longitude' => ['required_if' => '按距离排序需要获得您的位置信息', 'numeric' => '位置不可用'],
                'latitude' => ['required_if' => '按距离排序需要获得您的位置信息', 'numeric' => '位置不可用']
            ]
        ],
        'Goods' => [
            'SearchRequest' => [
                'title' => ['required' => '请输入商品名称', 'string' => '商品名称格式错误', 'between' => '商品名称长度错误'],
                'sort_rule' => ['in' => '排序规则有误'],
                'price_range' => ['json' => '价格区间规则有误'],
            ],
            'SkuDetailRequest' => [
                'goods_id' => ['required' => '请传入商品id', 'integer' => '商品ID格式错误'],
                'properties' => ['required' => '请选择商品属性', 'string' => '属性值格式错误']
            ]
        ],
        'Cart' => [
            'AddRequest' => [
                'sku_id' => ['required' => '请选择商品', 'integer' => '商品格式错误', 'gt' => '请选择正确的商品'],
                'num' => ['required' => '请选择商品数量', 'integer' => '商品数量格式错误', 'gt' => '商品数量需大于 0'],
            ],
        ],
        'User' => [
            'ChangePasswordRequest' => [
                'old_password' => ['required' => '请输入原密码'],
                'password' => ['required' => '请输入密码', 'confirmed' => '两次密码不一致'],
                'password_confirmation' => ['required' => '请输入密码'],
            ],
            'UserPayPasswordRequest' => [
                'password' => ['required' => '请输入密码', 'confirmed' => '两次密码不一致'],
                'password_confirmation' => ['required' => '请输入密码'],
            ],
            'UpdatePayPasswordRequest' => [
                'old_password' => ['required' => '请输入原密码'],
                'password' => ['required' => '请输入密码', 'confirmed' => '两次密码不一致'],
                'password_confirmation' => ['required' => '请输入密码'],
            ],
            'UserCashRequest' => [
                'amount' => ['required' => '请输入提现金额'],
            ],
        ],
        'Order' => [
            'BuyRequest' => [
                'addr_id' => ['required' => '请选择收货地址', 'min' => '收货地址无效'],
                'sku_id' => ['required' => '请选择商品属性'],
                'num' => ['required' => '请选择购买数量'],
                'remark' => ['max' => '备注格式错误[最多255字符]']
            ],
            'PayRequest' => [
                'order_no' => ['required' => '订单号必传'],
                'channel' => ['required' => '请选择支付方式', 'in' => '当前仅支持支付宝']
            ],
        ],
        'Payment' => [
            'AppRequest' => [
                'pay_no' => ['required' => '支付单号缺失', 'string' => '支付单号格式错误', 'max' => '支付单号长度错误'],
                'order_no' => ['required' => '订单号缺失', 'string' => '订单号格式错误', 'max' => '订单号长度错误'],
                'amount' => ['required' => '请输入支付金额', 'gte' => '最少支付 0.01 元'],
                'type' => ['required' => '请选择订单类型', 'in' => '订单类型不存在'],
                'pay_type' => ['required' => '请选择支付方式', 'in' => '支付方式不存在'],
                'remark' => ['string' => '备注格式错误', 'max' => '备注过长'],
            ]
        ],
        'UserBank' => [
            'AddBankRequest' => [
                'phone' => [
                    'required' => '请输入手机号',
                    'digits' => '手机号长度错误'
                ],
                'name' => [
                    'required' => '请输入姓名',
                    'min' => '姓名长度错误'
                ],
                'bank_name' => [
                    'required' => '请输入银行名称',
                    'min' => '银行名称长度错误'
                ],
                'bank_account' => [
                    'required'  => '请输入银行卡号',
                    'digits_between' => '银行卡号长度不正确'
                ],
                'idcard' => [
                    'required'  => '请输入身份证号',
                    'digits' => '身份证号码长度错误'
                ]
            ]
        ],
    ],
    'Business' => [
        'Cert' => [
            'BusinessCertRequest' => [
                'business_name' => [
                    'required' => '请输入商家姓名'
                ],
                'business_card_id' => [
                    'required' => '请输入商家身份证号码'
                ],
                'business_bank_id' => [
                    'required' => '请选择银行卡'
                ],
                'business_idcard_positive' => [
                    'required' => '请选择上传身份证正面'
                ],
                'business_idcard_negative' => [
                    'required' => '请选择上传身份证反面'
                ],
                'company_name' => [
                    'required' => '请输入公司名称'
                ],
                'legal_name' => [
                    'required' => '请输入公司法人姓名'
                ],
                'industry_id' => [
                    'required' => '请选择行业'
                ],
                'province_id' => [
                    'required' => '请选择省份'
                ],
                'city_id' => [
                    'required' => '请选择城市'
                ],
                'district_id' => [
                    'required' => '请选择区/县'
                ],
                'address' => [
                    'required' => '请填写详细地址'
                ],
                'tel' => [
                    'required' => '请填写手机号码'
                ],
                'settled_type' => [
                    'required' => '请填写选择入驻方式'
                ],
                'company_license_pic' => [
                    'required' => '请上传营业执照'
                ],
                'longitude' => [
                    'required' => '请获取经纬度'
                ],
                'latitude' => [
                    'required' => '请获取经纬度'
                ],
                'code' => [
                    'required' => '请填写验证码'
                ],
                'identity_code' => [
                    'required' => '请填写邀请码'
                ],

            ],
        ],
        'Coupon' => [
            'GetCategoryRequest' => [
                'type' => [
                    'required' => '请选择优惠券类型',
                    'in' => '请选择正确的优惠券类型',
                ],
            ],
            'AddCouponRequest' => [
                'title' => [
                    'required' => '请填写优惠券标题',
                    'string' => '产品标题只允许中文、字母、数字',
                ],
                'description' => [
                    'required' => '请输入券描述',
                ],
                'start_time' => [
                    'required' => '请设置优惠券开始时间',
                ],
                'expire_time' => [
                    'required' => '请设置优惠券过期时间',
                ],
                'price' => [
                    'required' => '请输入券购买价格',
                    'numeric' => '请输入正确的购买价格',
                    'gt' => '券购买价格必须大于0',
                ],
                'goods_price' => [
                    'required' => '请输入商品价格',
                    'numeric' => '请输入正确的商品价格',
                    'gt' => '商品价格必须大于0',
                ],
                'picture' => [
                    'required' => '请上传封面图片',
                ],
                'stock' => [
                    'required' => '请输入库存数量'
                ]
            ],
            'DeleteCouponRequest' => [
                'ids' => [
                    'required' => '请选择要删除的优惠券',
                ],
            ],
            'GetBusinessCouponListRequest' => [
                'type' => [
                    'required' => '请选择优惠券类型',
                    'in' => '请选择正确的优惠券类型',
                ],
            ],
            'GenStockValueRequest' => [
                'num' => [
                    'required' => '请输入生成条数',
                    'integer' => '请输入1~99999的整数',
                    'between' => '请输入1~99999的整数',
                ],
            ],
            'AddCouponStockRequest' => [
                'coupon_id' => [
                    'required' => '请选择优惠券',
                ],
                'value' => [
                    'required' => '请输入券核销码',
                    'array' => '请正确券核销码',
                ],
            ],
            'CheckCouponStockRequest' => [
                'coupon_id' => [
                    'required' => '请选择优惠券'
                ],
                'value' => [
                    'required' => '核销码不能为空'
                ],
            ],
            'GetCouponRequest' => [
                'value' => [
                    'required' => '核销码不能为空',
                ],
            ],
            'AddShopDiscountRequest' => [
                'title' => [
                    'required' => '请填写商品标题',
                ],
                'picture' => [
                    'required' => '请上传产品图片',
                ]
            ],
            'AddVoucherRequest' => [
                'title' => [
                    'required' => '请填写抵用券标题',
                ],
                'goods_price' => [
                    'required' => '请填写抵用券金额',
                ],
                'reach_price' => [
                    'required' => '请填写抵用券满多少钱可以使用',
                ],
                'price' => [
                    'required' => '请填写购买金额',
                ],
                'stock' => [
                    'required' => '请填写库存量',
                ],
                'start_time' => [
                    'required' => '请选择开始时间',
                ],
                'expire_time' => [
                    'required' => '请选择过期时间',
                ],
                'instructions' => [
                    'required' => '使用说明',
                ],
            ],
            'GetCouponByIdRequest' => [
                'id' => [
                    'required'   => '请传递参数id'
                ],
            ],
            'GetCouponByTypeRequest' => [
                'type' => [
                    'required'   => '请传递参数type'
                ],
            ],
            'GetCouponByOrderNoRequest' => [
                'order_no' => [
                    'required' => '请传递订单编号'
                ],
            ],
        ],
        'Business' => [
            'ChangeJoiningWayRequest' => [
                'enable_full_discount' => [
                    'required_without_all' => '请选择至少一项加盟方式',
                ],
                'enable_coupon' => [
                    'required_without_all' => '请选择至少一项加盟方式',
                ],
                'enable_voucher' => [
                    'required_without_all' => '请选择至少一项加盟方式',
                ],
            ],
            'ChangeFullDiscountRateRequest' => [
                'full_discount_rate' => [
                    'required' => '请选择一项全店打折比例',
                    'in' => '请选择正确的全店打折比例',
                ],
            ],
            'ChangeInfoRequest' => [
                'name' => [
                    'required' => '商家简称不能为空',
                ],
                'logo' => [
                    'required' => '请上传商家LOGO',
                ],
                'province_id' => [
                    'required' => '请选择正确的省份',
                    'integer' => '省份格式错误',
                ],
                'city_id' => [
                    'required' => '请选择正确的市',
                    'integer' => '城市格式错误',
                ],
                'district_id' => [
                    'required' => '请选择正确的区/县',
                    'integer' => '区/县格式错误',
                ],
                'address' => [
                    'required' => '请输入详细地址',
                ],
                'longitude' => [
                    'required' => '位置信息有误',
                    'between' => '位置信息有误',
                ],
                'latitude' => [
                    'required' => '位置信息有误',
                    'between' => '位置信息有误',
                ],
                'tel' => [
                    'required' => '请输入联系电话',
                ],
            ],
        ],
        'User' => [
            'CashWithdrawalRequest' => [
                'bank_id' => [
                    'required' =>  '请传递银行卡id参数',
                ],
                'amount' =>  [
                    'required' =>  '请输入金额',
                ],
            ],
            'GetCashInfoRequest' => [
                'start_time' => [
                    'required' =>  '请传递查询的月份',
                ]
            ],
            'GetCashOneRequest' => [
                'id' => [
                    'required' =>  '请传递参数id',
                ]
            ],
            'CheckPwdRequest' => [
                'pwd' => [
                    'required' => '请输入密码'
                ]
            ],
        ]
    ],
];
